# $Id$
# Maintainer: Ionut Biru <ibiru@archlinux.org>

pkgname=mythes-ro
pkgver=3.3
pkgrel=5
pkgdesc="Romanian thesaurus"
arch=('any')
url="http://sourceforge.net/projects/rospell/"
license=('GPL')
optdepends=('libmythes: offers thesaurus library functions')
source=(http://downloads.sourceforge.net/rospell/th_ro_RO.${pkgver}.zip)
md5sums=('3ed53f2e3774fec2d6addd88c4ac7170')

package() {
  cd "${srcdir}"

  install -dm755 ${pkgdir}/usr/share/mythes

  install -m644 th_ro_RO.dat "${pkgdir}/usr/share/mythes/th_ro_RO_v2.dat"
  install -m644 th_ro_RO.idx "${pkgdir}/usr/share/mythes/th_ro_RO_v2.idx"

  # the symlinks
  install -dm755 ${pkgdir}/usr/share/myspell/dicts
  pushd $pkgdir/usr/share/myspell/dicts
    for file in $pkgdir/usr/share/mythes/*; do
      ln -sv /usr/share/mythes/$(basename $file) .
    done
  popd
}
